FTP_PUT_FILE Function
Syntax
Arguments
- addressCharacter
The FTP address of the transmission.
- userCharacter
The user's identity.
- passwordCharacter
The user's password.
- source_fileCharacter
The file to send.
- destination_fileCharacter
The file to save remotely.
- backgroundLogical
Default = .T.. If .T., the FTP dialog is displayed as a modeless dialog. If .F., the FTP dialog is modal, and the script pauses until the FTP transfer is complete.
- titleCharacter
Default = "FTP File Transfer". The title of the dialog box.
Returns
- ResultCharacter
When background is .F., the returned value will be "OK", "ERROR" or "Cancel", depending on the result of the file transfer.
Description
Uploads a file using FTP
Discussion
The FTP_PUT_FILE() function sends a file in the background over a FTP connection.
When publishing via FTP, Alpha Anywhere first opens a connection to port 21 on the remote server. This port is used for exchange of control information and for negotiating the second port to use. The second port is chosen by Windows and will be some value above 1024. This is the port used for the actual transfer of files. This is all standard FTP behavior.
Alpha Anywhere has no control over the second port used. Norton Antivirus apparently looks for activity on certain ports and flags any traffic on those ports as activity by a trojan. Phineas Phucker uses port 2801. Striker uses port 2565. WinCrash uses ports 2583, 3024, 4092 and 5742. These are all perfectly acceptable for use by an FTP upload.
FTP_PUT_FILE("www.alphasoftware.com", "username", "password", "c:\learningcenter.asp","/technical_documentation/learningcenter.asp")
See Also